#cmake demo
cmake_minimum_required(VERSION 3.15)

set(TARGET_NAME "symbol_cu")
set(LIB_NAME "lib${TARGET_NAME}.so")
project(${TARGET_NAME})

set(MACA_INC_PATH "${MACA_PATH}/include")
set(MACA_COMMON_INC_PATH "${MACA_PATH}/include/common")
set(MCR_INC_PATH "${MACA_PATH}/include/mcr")
set(MCLOG_INC_PATH "${MACA_PATH}/include/mclog")

include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include
                    ${CMAKE_CURRENT_SOURCE_DIR}/src/impl
                    ${MACA_INC_PATH}
                    ${MCR_INC_PATH}
                    ${MCLOG_INC_PATH}
                    ${MACA_COMMON_INC_PATH})

set(CUSYMBOLSRC
    ${CMAKE_CURRENT_SOURCE_DIR}/src/symbol_cu_runtime.cpp
    ${CMAKE_CURRENT_SOURCE_DIR}/src/symbol_cu_driver.cpp
)
link_directories(${MACA_PATH}/lib)
add_library(${TARGET_NAME} SHARED ${CUSYMBOLSRC})
target_link_libraries(${TARGET_NAME} PRIVATE runtime_cu)
## Install information
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME} DESTINATION ${LIB_DEST_DIR})

